<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Title</title>
</head>
<body>
</body>
<script>
  const i = '2';

  switch (i) {
    case 1:
      console.log('number 1');
      break;
    case '2':
      console.log('String 2');
  }

  // i = 1  => number 1
  // i = '1' => ''
  // i = 2 => ''
  // i = '2' => String 2


</script>
</html>